<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<title></title>
	<link rel="stylesheet" href="">
	<script src="js/jquery-1.12.3.min.js"></script>
</head>
<body>
	<form id="loginForm">
		<label>账号：<input type="text" name="id" value="142419602237857542"></label>
		<label>密码：<input type="text" name="password" value=""></label>
		<button class="login">登录</button>
	</form>

	<script>
		$('.login').click(function(event) {
			$.ajax({
				url: ' http://192.168.18.205/exam-api/login',
				type: 'post',
				data: $('#loginForm').serialize(),
				success: function (data) {
					console.log(data);
					window.location.href = "test.html";
				}
			});
			return false;
		});
	</script>
</body>
</html>